home *** CD-ROM | disk | FTP | other *** search
/ Tricks of the Mac Game Programming Gurus / TricksOfTheMacGameProgrammingGurus.iso / More Source / C⁄C++ / Xconq 7.0d37 / source / kernel / print.h < prev    next >
Encoding:
C/C++ Source or Header  |  1995-03-14  |  1.7 KB  |  57 lines  |  [TEXT/KAHL]

  1. /* Definitions for printing in Xconq.
  2.    Copyright (C) 1994 Stanley T. Shebs and Massimo Campostrini.
  3.  
  4. Xconq is free software; you can redistribute it and/or modify
  5. it under the terms of the GNU General Public License as published by
  6. the Free Software Foundation; either version 2, or (at your option)
  7. any later version.  See the file COPYING.  */
  8.  
  9. typedef struct a_legend {
  10.     int ox, oy;  /* starting point */
  11.     int dx, dy;  /* displacement */
  12.     float angle, dist;  /* polar displacement (redundant, but useful) */
  13. } Legend;
  14.  
  15. /* Parameters to control view printing. */
  16.  
  17. typedef struct a_print_parameters {
  18.     /* binary flags */
  19.     int corner_coord;
  20.     int terrain_dither;
  21.     int terrain_double;
  22.     int features;
  23.     int cell_summary;
  24.     int cm;  /* otherwise inches */
  25.     /* integer flags */
  26.     int names;
  27.     /* lengths */
  28.     double cell_size;
  29.     double cell_grid_width;
  30.     double border_width;
  31.     double connection_width;
  32.     double page_width;
  33.     double page_height;
  34.     double top_margin;
  35.     double bottom_margin;
  36.     double left_margin;
  37.     double right_margin;
  38.     /* gray levels */
  39.     double terrain_gray;
  40.     double enemy_gray;
  41. } PrintParameters;
  42.  
  43. /* Prototypes. */
  44.  
  45. extern void init_ascii_print PROTO ((PrintParameters *pp));
  46. extern void dump_ascii_view PROTO ((Side *side, PrintParameters *pp, char *filename));
  47.  
  48. extern void init_ps_print PROTO ((PrintParameters *pp));
  49. extern void dump_ps_view PROTO ((Side *side, PrintParameters *pp, char *filename));
  50.  
  51. extern int ps_load_bitmap PROTO ((Side *side, int u));
  52. extern int store_bitmap PROTO ((int u));
  53. extern int make_ps_images PROTO ((void));
  54. extern char *add_esc_char PROTO ((char ch));
  55. extern char *add_esc_string PROTO ((char *str));
  56. char *pad_blanks PROTO ((char *str, int n));
  57.